<?php
class Group extends AppModel {
    var $name = 'Group';
    var $useTable = 'groups';
    var $hasMany = array('User');
    var $hasAndBelongsToMany = array(
            'Permission' => array('className' => 'Permission',
                        'joinTable' => 'permission_groups',
                        'foreignKey' => 'group_id',
                        'associationForeignKey' => 'permission_id',
                        'unique' => true
            )
    );
}

?>